package demo530;

public class Employee {
    private String employeeId;
    private String name;
    private String password;
    private final int age; // 添加final表示一旦赋值不可更改

    // 构造方法
    public Employee(String employeeId, String name, String password, int age) {
        this.employeeId = employeeId;
        this.name = name;
        this.password = password;
        this.age = age;
    }

    // Getter 方法
    public String getEmployeeId() {
        return employeeId;
    }

    public String getName() {
        return name;
    }

    public String getPassword() {
        return password;
    }

    public int getAge() {
        return age;
    }

    // Setter 方法（如果需要修改属性值）
    public void setPassword(String password) {
        this.password = password;
    }
}



